<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>浮动</title>
	<style type="text/css">
		.con{
			width: 400px;
			height: 80px;
			border:1px solid gold;
			margin:50px auto 0;
		}
		.con div{
			width: 60px;
			height: 60px;
			margin: 10px;
			/* display: inline-block; */
			/* float: left; */
		}
		.box01{
			background-color: green;
			float: left;
		}
		
		.box02{
			background-color: pink;
			float: right;
		}

		.con2{
			width: 400px;
			height: 400px;
			border:1px solid #000;
			margin:50px auto 0;
		}
		.con2 div{
			width: 100px;
			height: 100px;
			background-color: gold;
			margin:15px;
			float: left;
		}


	</style>
</head>
<body>
	<div class="con">
		<div class="box01"></div>
		<div class="box02"></div>
	</div>
	
	<div class="con2">
		<div>1</div>
		<div>2</div>
		<div>3</div>
		<div>4</div>
		<div>5</div>
		<div>6</div>
		<div>7</div>
		<div>8</div>
		<div>9</div>
	</div>



</body>
</html>